<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ page isELIgnored="false"%>
<%@ page import="dao.CompanyDao"%>
<%@ page import="bean.Company"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link href="<%=request.getContextPath()%>/css/SonPage.css"
	rel="stylesheet" type="text/css">
<link href="<%=request.getContextPath()%>/css/Element.css"
	rel="stylesheet" type="text/css">
<link href="<%=request.getContextPath()%>/css/easyui.css"
	rel="stylesheet" type="text/css">
<link href="<%=request.getContextPath()%>/css/icon.css"
	rel="stylesheet" type="text/css">
<script src="<%=request.getContextPath()%>/js/Mtopt_1.1.js"
	type="text/javascript"></script>
<script src="<%=request.getContextPath()%>/js/SonPage.js"
	type="text/javascript"></script>
<script src="<%=request.getContextPath()%>/js/jquery-1.8.3.js"
	type="text/javascript"></script>
<script src="<%=request.getContextPath()%>/js/jquery.easyui.min.js"
	type="text/javascript"></script>
<script src="<%=request.getContextPath()%>/js/easyui-lang-zh_CN.js"
	type="text/javascript"></script>
<style type="text/css">
.DivShowData {
	position: static;
	width: 1180px;
	height: 600px;
}

.table {
	width: 990px;
	border: 1px solid #95B8E7;
}
</style>
</head>
<body>
	<%
		CompanyDao cd = new CompanyDao();
		List<Company> list = cd.getAllCompany();
	%>
	<div class="DivShowData panel-noscroll">
		<form action="<%=request.getContextPath()%>/CompanyServlet"
			method="post">
			<div class="panel datagrid" style="width: 1180px;">
				<div class="panel-header" style="width: 1168px;">
					<div class="panel-title">企业管理</div>
					<div class="panel-tool"></div>
				</div>
				<div class="datagrid-wrap panel-body" title=""
					style="width: 1178px; height: 571px;">
					<div class="datagrid-toolbar">
						<table cellspacing="0" cellpadding="0">
							<tbody>
								<tr>
									<td><a href="../company/addcompany.jsp"
										class="l-btn l-btn-plain" id=""> <span class="l-btn-left">
												<span class="l-btn-text icon-add l-btn-icon-left">增加</span>
										</span>
									</a></td>
									<!--  <td>
                         <a href="ventEdit.jsp" class="l-btn l-btn-plain" id="">
                           <span class="l-btn-left">
                           <span class="l-btn-text icon-redo l-btn-icon-left">排放口编辑</span>
                           </span>
                         </a>
                     </td> -->
								</tr>
							</tbody>
						</table>
					</div>
					<div class="datagrid-view" style="width: 1178px; height: 542px;">
						<style type="text/css">
div.datagrid-cell-c1-PolluteSourceNo {
	width: undefinedpx;
}

div.datagrid-cell-c1-PolluteSourceName {
	width: 92px;
}

div.datagrid-cell-c1-GroupName {
	width: 72px;
}

div.datagrid-cell-c1-TypeName {
	width: 32px;
}

div.datagrid-cell-c1-IndustryName {
	width: 92px;
}

div.datagrid-cell-c1-OperateScaleName {
	width: 52px;
}

div.datagrid-cell-c1-AttentionName {
	width: 32px;
}

div.datagrid-cell-c1-TakeoverName {
	width: 32px;
}

div.datagrid-cell-c1-PleaceName {
	width: 52px;
}

div.datagrid-cell-c1-9 {
	width: 12px;
}
</style>
						<div class="datagrid-view1" style="width: 0px;">
							<div class="datagrid-header" style="width: 0px; height: 49px;"></div>
							<div class="datagrid-body"
								style="width: 0px; margin-top: 0px; height: 492px;"></div>
							<div class="datagrid-footer" style="width: 0px;">
								<div class="datagrid-footer-inner" style="display: none;"></div>
							</div>
						</div>
						<div class="datagrid-view2" style="width: 1178px;">
							<div class="datagrid-header">
								<div class="datagrid-header-inner" style="display: block;">
									<table class="datagrid-htable">
										<tr class="datagrid-header-row">
											<td rowspan="2" field="PolluteSourceName">
												<div class="datagrid-cell"
													style="width: 205px; text-align: center;">
													<span>企业名</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td colspan="4">
												<div class="datagrid-cell-group">行业</div>
											</td>
											<td colspan="2">
												<div class="datagrid-cell-group">地址</div>
											</td>
										</tr>
										<tr class="datagrid-header-row">
											<td field="IndustryName">
												<div class="datagrid-cell"
													style="width: 201px; text-align: center;">
													<span>行业</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td field="OperateScaleName">
												<div class="datagrid-cell"
													style="width: 117px; text-align: center;">
													<span>规模</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td field="AttentionName">
												<div class="datagrid-cell"
													style="width: 75px; text-align: center;">
													<span>关注</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td field="TakeoverName">
												<div class="datagrid-cell"
													style="width: 75px; text-align: center;">
													<span>接管</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td field="PleaceName">
												<div class="datagrid-cell"
													style="width: 117px; text-align: center;">
													<span>地区</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td field="9" class="">
												<div class="datagrid-cell"
													style="width: 36px; text-align: center;">
													<span>地图</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
											<td rowspan="2" field="PolluteSourceName">
												<div class="datagrid-cell"
													style="width: 284px; text-align: center;">
													<span>操作</span> <span class="datagrid-sort-icon">&nbsp;</span>
												</div>
											</td>
										</tr>
									</table>
								</div>
							</div>
							<div class="datagrid-body"
								style="width: 1178px; margin-top: 0px; height: 492px;">
								<table class="datagrid-btable" cellspacing="0" cellpadding="0"
									border="0" style="table-layout: auto;">
									<tbody>
										<%
											for (Company company : list) {
										%>
										<tr id="datagrid-row-r1-2-0" datagrid-row-index="0"
											class="datagrid-row">
											<td width="213px" field="PolluteSourceName"><div
													style="text-align:center;height:auto;margin:auto;"
													class="datagrid-cell datagrid-cell-c1-PolluteSourceName"><%=company.getCompanyName()%></div></td>
											<td width="213px" field="IndustryName" style="text-align:center"><div
													style="text-align:center;height:auto;margin:auto;"
													class="datagrid-cell datagrid-cell-c1-IndustryName"><%=company.getClasses()%></div></td>
											<td width="127px" field="OperateScaleName"><div
													style="text-align:center;height:auto;margin:auto;"
													class="datagrid-cell datagrid-cell-c1-OperateScaleName"><%=company.getScale()%></div></td>
											<td width="85px" field="AttentionName"><div
													style="text-align:center;height:auto;margin:auto;"
													class="datagrid-cell datagrid-cell-c1-AttentionName"><%=company.getAttention()%></div></td>
											<td width="85px" field="TakeoverName"><div
													style="text-align:center;height:auto;margin:auto;"
													class="datagrid-cell datagrid-cell-c1-TakeoverName"><%=company.getAdapter()%></div></td>
											<td width="127px" field="PleaceName"><div
													style="text-align:center;height:auto;margin:auto;"
													class="datagrid-cell datagrid-cell-c1-PleaceName"><%=company.getArea()%></div></td>
											<td width="46px" field="9"><a title="查看地图" href="#"><img
													alt="" src="../img/View.png"
													style="width:25px;height:25px;"></a></td>
											<td style="width:90px;margin:auto;text-align:center"><a
												href="../company/updcompany.jsp?comid=<%=company.getCompany_id()%>">修改</a>
											</td>
											<td style="width:90px;margin:auto;text-align:center"><a
												href="<%=request.getContextPath()%>/deleteComServlet?comid=<%=company.getCompany_id()%>">删除</a>
											</td>
											<td style="width:90px;margin:auto;text-align:center"><a
												href="<%=request.getContextPath()%>/vent/editvent.jsp?company_id=<%=company.getCompany_id()%>">排放口编辑</a>
											</td>
										</tr>
										<%}%>
									</tbody>
								</table>
							</div>
							<div class="datagrid-footer" style="width: 1178px;">
							<div class="datagrid-footer-inner" style="display: none;"></div>
						</div>
						</div>
					</div>
				</div>
			</div>
		</form>
	</div>
</body>
</html>